(require 'abbrev)

(setq default-abbrev-mode t)  

(define-skeleton 1exp 
  "Input #+BEGIN_EXAMPLE #+END_EXAMPLE in org-mode"
""
"#+BEGIN_EXAMPLE\n"
 _ "\n" 
"#+END_EXAMPLE"
)
(define-abbrev org-mode-abbrev-table "iexp" "" '1exp)


(define-skeleton 1src 
  "Input #+begin_src #+end_src in org-mode"
""
"#+begin_src lisp \n"
 _ "\n" 
"#+end_src"
) 
(define-abbrev org-mode-abbrev-table "isrc" "" '1src)

(define-skeleton skeleton-c-mode-main-func
  "generate int main(int argc, char * argc[]) automatic" nil
   "int main ( int argc, char* argv[] ) {\n "
    > _ >"\n" 
    > "return 0;\n"
   "}"
)
(define-abbrev c-mode-abbrev-table "main" "" 'skeleton-c-mode-main-func)

(define-skeleton skeleton-note-func 
   "generate #####Note::" nil
   "#####Note:: "
)

(define-abbrev global-abbrev-table "inote" "" 'skeleton-note-func)
